/*
Copyright (c) [2019年5月1日] [吴超]
[MBT_studio] is licensed under Mulan PSL v2.
You can use this software according to the terms and conditions of the Mulan PSL v2.
You may obtain a copy of Mulan PSL v2 at:
		 http://license.coscl.org.cn/MulanPSL2
THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
See the Mulan PSL v2 for more details.
*/
#pragma once

#include "节点/插座/C_单值矢量插座.h"

class C_Vector_模板 : public C_插座基类 {

public:
	C_Vector_模板(std::string name);
	~C_Vector_模板();

	void*	m_引用数据;

	void*	f_getData();
	void	f_setData(void* data, int64 ID = -1);
	//void	f_删除元素(uint32 id);

};
#define DEF_转换为Vector_模板插座(socket) dynamic_cast<C_Vector_模板*>( (socket) )

#define DEF_Vector_模板插座创建_I(name)  socket = new C_Vector_模板( (name) ); f_add插座(socket, E_插座方向::e_插座Type_输入);
#define DEF_Vector_模板插座创建_O(name)  socket = new C_Vector_模板( (name) ); f_add插座(socket, E_插座方向::e_插座Type_输出);


/*class C_引用数据插座 : public C_插座基类 {

public:2
	C_引用数据插座(std::string name);
	~C_引用数据插座();

	S_引用插座数据映射		m_引用数据;

	void*		f_getData();
	vec3		f_getVec3();
	std::vector<int8>*		f_getI8_1D(const int64& ID = -1);
	std::vector<float32>*	f_getF32_1D(const int64& ID = -1);
	std::vector<vec3>*		f_getVec3_1D(const int64& ID = -1);
	void		f_setData(void* data, int64 ID = -1);
	
	PyObject*	f_输出_bl数据(PyObject* bl_data = 0);

};
#define DEF_转换为引用插座(socket) dynamic_cast<C_引用数据插座*>( (socket) )
#define DEF_转换为引用数据(socket) ((S_引用插座数据映射*)(DEF_转换为引用插座( (socket) )->f_getData()))

#define DEF_引用插座创建_I(name)  socket = new C_引用数据插座( (name) ); f_add插座(socket, E_插座输出方向::e_插座Type_输入);
#define DEF_引用插座创建_O(name)  socket = new C_引用数据插座( (name) ); f_add插座(socket, E_插座输出方向::e_插座Type_输出);


void f_引用插座绑定数据(C_插座基类* 引用插座, C_插座基类* 数据插座, 
	E_数据赋值方式	赋值方式	= E_数据赋值方式::e_赋值_直接,
	int64			位置		= -1
);

void f_引用插座绑定数据(C_插座基类* 引用插座, void* 数据插座, E_值类型 type,
	E_数据赋值方式	赋值方式 = E_数据赋值方式::e_赋值_直接,
	int64			位置 = -1
);*/









class C_1dArray_元素 : public C_插座基类 {

public:
	C_1dArray_元素(std::string name);
	~C_1dArray_元素();

	std::vector<void*>	m_Value;

	void*		f_getData();
	void		f_setData(void* data, int64 ID = -1);

};
#define DEF_转换为1dArray_元素插座(socket) dynamic_cast<C_1dArray_元素*>( (socket) )

#define DEF_1dArray_元素创建_I(name)  socket = new C_1dArray_元素( (name) ); f_add插座(socket, E_插座方向::e_插座Type_输入);
#define DEF_1dArray_元素创建_O(name)  socket = new C_1dArray_元素( (name) ); f_add插座(socket, E_插座方向::e_插座Type_输出);









